🎖️GitЯра🎖️
Node / meshtastic / Meshtastic-Android / files / app / src / main / java / com / geeksville / mesh / repository / usb / README.md
Displaying Raw • View rendered • Download
app/src/main/java/com/geeksville/mesh/repository/usb/README.md 78274c792318331b11ab64cd28e58e829875b8c2 (78274c79) Text, 1.19 KB
Tc9d1d9# USB Module
This module provides a repository for acessing USB devices.
Tc9d1d9## Device Support
In order to be picked up, devices need to be supported by two different mechanisms:
Tff7b72- Android needs to be supplied with a device filter so that it knows what devices to inform
the app about. These are expressed as vendor and device IDs in Ta5d6ff`src/res/xml/device_filter.xml`.
Tff7b72- The USB driver library also needs to have a mapping between the vendor + device IDs and the
driver to use for communications. Many mappings are already natively supported by the driver
but unknown devices can have manual mappings added via Ta5d6ff`ProbeTableProvider`.
The [Tff7b72Serial USB Terminal](Te6edf3https://play.google.com/store/apps/details?id=de.kai_morich.serial_usb_terminal)
app in the Google Play Store seems to be a good app for determining both the vendor and
device IDs as well as testing different underlying drivers.
Tc9d1d9## Testing
When granting permissions to a USB device, the Android platform remembers the user's decision.
In order to test the permission granting logic, re-install the app. This will cause Android
to forget previously granted permissions and will re-trigger the permission acquisition logic.
Served by rngit 1.5.2 - Generated in 0.1s